<!--
 * @Author: 严晗 823841034@qq.com
 * @Date: 2023-06-19 16:28:39
 * @LastEditors: 严晗 823841034@qq.com
 * @LastEditTime: 2023-11-09 17:18:08
 * @FilePath: /yike-admin/Users/yanhan/vite-project/src/App.vue
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<script setup>
// 引入elementplus中文设置组件及相关配置
import { ElConfigProvider } from 'element-plus'
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
const locale = zhCn

// 判断屏幕宽度，设置侧边菜单栏宽度
import { getScreen } from '~/composables/utils'
import { useStore } from 'vuex';
const store = useStore()
console.log(getScreen());
if(getScreen() <= 1){
	// 小于 1 的时候，则为小屏（ipad、iPhone）
	store.commit('SET_MENU_WIDTH')
}
</script>

<template>
	<!-- 设置中文组件 -->
	<el-config-provider :locale="locale">
		<router-view></router-view>
	</el-config-provider>
</template>

<style lang="scss">
#nprogress .bar {
	background: rgb(14, 39, 230) !important;
}

.el-dropdown-link:focus {
	outline: none;
}
</style>
